Game.plane=function(x,y,width,height){
	this.x=x||0;
	this.y=y||0;
	this.width=width||planeWidth;
	this.height=height||planeHeight;
	this.life=1;

	this.img=new Image();
	this.img.src='./images/player_01.png';
}

Game.plane.prototype.hit=function(item){
	function pointInRect(x,y,rect){
		if(x>rect.x && x<rect.x+rect.width &&
			y>rect.y && y<rect.y+rect.height){
			return true;
		}
		return false;
	}
	var x=this.x;
	var y=this.y;
	if(pointInRect(x,y,item)||
		pointInRect(x+this.width,y,item)||
		pointInRect(x,y+this.height,item)||
		pointInRect(x+this.width,y+this.height,item)){
		return true;
	}
	return false;
}